using UnityEngine;
// [Assembly-CSharp.dll].SafeAreaDetection
public class SafeAreaDetection : MonoBehaviour
{
    
    #region SafeAreaDetection.SafeAreaChanged
    // [Assembly-CSharp.dll].SafeAreaDetection.SafeAreaChanged
    public sealed class SafeAreaChanged : MulticastDelegate
    {
        // Methods
        public SafeAreaChanged(object object, IntPtr method)
        {
            var val_1;
            mem[1152921504930430416] = method;
            mem[1152921504930430440] = method;
            mem[1152921504930430432] = object;
            mem[1152921504930430464] = this;
            if((method & 1) == 0)
            {
                goto label_0;
            }
            
            if(((method + 83) & 16) != 0)
            {
                goto label_1;
            }
            
            if((method + 82) != 1)
            {
                goto label_2;
            }
            
            val_1 = 4303984;
            goto label_7;
            label_0:
            if(object == null)
            {
                    throw 0;
            }
            
            label_2:
            mem[1152921504930430424] = ???;
            mem[1152921504930430464] = ???;
            goto label_5;
            label_1:
            if((method + 82) == 1)
            {
                    val_1 = 4303996;
            }
            else
            {
                    val_1 = 4304048;
            }
            
            label_7:
            mem[1152921504930430424] = val_1;
            label_5:
            mem[1152921504930430456] = 4303872;
        }
        public virtual void Invoke(UnityEngine.Rect safeArea)
        {
            goto x2;
        }
        public virtual System.IAsyncResult BeginInvoke(UnityEngine.Rect safeArea, System.AsyncCallback callback, object object)
        {
            return (System.IAsyncResult)this;
        }
        public virtual void EndInvoke(System.IAsyncResult result)
        {
        
        }
    
    }
    
    #endregion
    
    // Fields
    private static SafeAreaDetection.SafeAreaChanged OnSafeAreaChanged;
    private UnityEngine.Rect _safeArea;
    
    // Methods
    public static void add_OnSafeAreaChanged(SafeAreaDetection.SafeAreaChanged value)
    {
        do
        {
            if((System.Delegate.Combine(a:  mem[536892191], b:  value)) != null)
        {
                if(null != 536900015)
        {
            goto label_2;
        }
        
        }
        
        }
        while(mem[536892191] != mem[536892191]);
        
        return;
        label_2:
    }
    public static void remove_OnSafeAreaChanged(SafeAreaDetection.SafeAreaChanged value)
    {
        do
        {
            if((System.Delegate.Remove(source:  mem[536892191], value:  value)) != null)
        {
                if(null != 536900015)
        {
            goto label_2;
        }
        
        }
        
        }
        while(mem[536892191] != mem[536892191]);
        
        return;
        label_2:
    }
    private void Awake()
    {
        UnityEngine.Rect val_1 = UnityEngine.Screen.safeArea;
        this._safeArea = val_1;
        mem[1152921504930430428] = val_1.m_YMin;
        mem[1152921504930430432] = val_1.m_Width;
        mem[1152921504930430436] = val_1.m_Height;
    }
    private void Update()
    {
        UnityEngine.Rect val_11;
        double val_12;
        val_11 = this._safeArea;
        UnityEngine.Rect val_1 = UnityEngine.Screen.safeArea;
        if((UnityEngine.Rect.op_Inequality(lhs:  new UnityEngine.Rect() {m_XMin = val_11, m_YMin = V9.16B, m_Width = V10.16B, m_Height = V11.16B}, rhs:  new UnityEngine.Rect() {m_XMin = val_1.m_XMin, m_YMin = val_1.m_YMin, m_Width = val_1.m_Width, m_Height = val_1.m_Height})) == false)
        {
                return;
        }
        
        UnityEngine.Rect val_3 = UnityEngine.Screen.safeArea;
        this._safeArea = val_3;
        mem[1152921504930430428] = val_3.m_YMin;
        mem[1152921504930430432] = val_3.m_Width;
        mem[1152921504930430436] = val_3.m_Height;
        if(mem[536892191] == 0)
        {
                return;
        }
        
        val_11 = ???;
        val_12 = ???;
        goto mem[536892191] + 24;
    }
    public SafeAreaDetection()
    {
    
    }

}
